//
//  BBFilteredDetector.h
//  BBTouch
//
//  Created by ben smith on 27/09/08.
//  This file is part of BBTouch.
//
//  BBTouch is free software: you can redistribute it and/or modify
//  it under the terms of the GNU Lesser General Public License as published by
//  the Free Software Foundation, either version 3 of the License, or
//  (at your option) any later version.

//  BBTouch is distributed in the hope that it will be useful,
//  but WITHOUT ANY WARRANTY; without even the implied warranty of
//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//  GNU Lesser General Public License for more details.

//  You should have received a copy of the GNU Lesser General Public License
//  along with BBTouch.  If not, see <http://www.gnu.org/licenses/>.
// 
//  Copyright 2008 Ben Britten Smith ben@benbritten.com .
//

#import <Cocoa/Cocoa.h>
#import <OpenCV/OpenCV.h>

#import "BBBlobDetector.h"

@interface BBFilteredDetector : BBBlobDetector {
	int highpassValue;
	int noiseValue;
	int threshValue;
	int threshSize;

	NSImage * noiseReduxImage;
	NSImage * highPassImage;
	NSImage * bgSubtractionImage;
	NSImage * finalImage;
	
	unsigned char *finalBytes;

	CvRect cvROI;
	
	IplImage* srcIpl;
	IplImage* bgIpl;
	IplImage* bgSubtractionIpl;
	IplImage* highpassIpl;
	IplImage* noiseIpl;
	IplImage* finalIpl;
	
}

@property (copy) NSImage * noiseReduxImage;
@property (copy) NSImage * highPassImage;
@property (copy) NSImage * bgSubtractionImage;
@property (copy) NSImage * finalImage;
@property (assign) int highpassValue;
@property (assign) int noiseValue;
@property (assign) int threshValue;
@property (assign) int threshSize;	

-(void)filterImage;

@end
